import React from 'react'
import './index.css'
const index = (props) => {
    let { steps } = props
    return (
        <ul className='stack'>
            {steps.map((s, idx) => (
                <li
                    key={idx}
                    style={{
                        backgroundColor: s.color,
                        marginLeft: s.stack * 48 + 'px',
                    }}
                >
                    <div>{s.text}</div>
                </li>
            ))}
        </ul>
    )
}

export default index
